package com.example.oauth2;

import org.springframework.boot.*;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.core.env.ConfigurableEnvironment;

@SpringBootApplication
public class Oauth2Application {
    /**
     * 一个请求进来， 先按照顺序进入过滤器链{@link jakarta.servlet.Filter} 然后到达{@link jakarta.servlet.Servlet} 最后按照过滤器相反的顺序再走一遍
     * 请求入口 {@link jakarta.servlet.Servlet}
     * 请求的入口 {@link jakarta.servlet.http.HttpServlet}
     * 所有的请求都经过 {@link org.springframework.web.servlet.DispatcherServlet}
     * <p>
     *     启动创建的上下文是AnnotationConfigApplicationContext 或 GenericApplicationContext
     *{@link org.springframework.boot.DefaultApplicationContextFactory#createDefaultApplicationContext()}
     * </p>
     *
     * {@link org.springframework.boot.SpringApplication#prepareContext(DefaultBootstrapContext, ConfigurableApplicationContext, ConfigurableEnvironment, SpringApplicationRunListeners, ApplicationArguments, Banner)}
     * {@link org.springframework.boot.SpringApplication#applyInitializers(ConfigurableApplicationContext)}
     * {@link org.springframework.boot.context.ContextIdApplicationContextInitializer#initialize(ConfigurableApplicationContext)}
     * {@link org.springframework.beans.factory.support.DefaultListableBeanFactory#registerSingleton(String, Object)}
     * {@link org.springframework.beans.factory.support.DefaultSingletonBeanRegistry#registerSingleton(String, Object)}
     * @param args String[]
     */
    public static void main(String[] args) {
        SpringApplication.run(Oauth2Application.class, args);
    }
}
